package com.hooya.fa.eu.biz.business;

import com.hooya.fa.eu.biz.business.service.Insert_Add_Invoice;
import com.hooya.fa.eu.biz.business.service.Insert_Transfer_Invoice;
import com.hooya.fa.eu.biz.business.service.Update_InvoiceNo;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Slf4j
@RequiredArgsConstructor
public class GenerateInvoices_03 {

	private final Insert_Add_Invoice insert_Add_Invoice;

	private final Insert_Transfer_Invoice insert_Transfer_Invoice;

	private final Update_InvoiceNo update_InvoiceNo;


	public void generateInvoices_03(String startDate, String endDate) {

		insertToInvoice_two(startDate, endDate);
		hjm();
		updateInvoiceNo(startDate, endDate);

	}

	private void insertToInvoice_two(String startDate, String endDate) {
		insert_Add_Invoice.insert_add_invoice(startDate);
		insert_Transfer_Invoice.insert_transfer_invoice(startDate);
	}

	private void hjm() {
		System.out.println("调用黄金木的接口");
	}

	private void updateInvoiceNo(String startDate, String endDate) {
		update_InvoiceNo.update_invoiceno(startDate, endDate);
	}


}
